package com.mabs.ground.client.module.connexion.view;

import com.github.gwtbootstrap.client.ui.Button;
import com.github.gwtbootstrap.client.ui.CheckBox;
import com.github.gwtbootstrap.client.ui.PasswordTextBox;
import com.github.gwtbootstrap.client.ui.TextBox;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.HasClickHandlers;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.HasValue;
import com.google.gwt.user.client.ui.Widget;

/**
 * @author <a href="Email: mohamedarbi.benslimane@allence-tunisie.com">Ben Slimane Arbi</a>
 * @version 1.0
 * @since 1.0 - 25 juil. 2014 - 19:40:00
 */
public class ConnexionViewImpl extends Composite implements ConnexionView {

	interface MyUiBinder extends UiBinder<Widget, ConnexionViewImpl> {
	}

	private static MyUiBinder uiBinder = GWT.create(MyUiBinder.class);

	@UiField
	TextBox email;
	@UiField
	PasswordTextBox password;
	@UiField
	CheckBox rememberMe;
	@UiField
	Button valider;
	

	public ConnexionViewImpl() {
		initWidget(uiBinder.createAndBindUi(this));
	}

	public HasValue<String> getUserName() {
		return email;
	}

	public HasValue<String> getPassword() {
		return password;
	}
	public HasValue<Boolean> getRememberMe() {
		return rememberMe;
	}
	public HasClickHandlers getValiderClickHandlers(){
		return valider;
	}
}
